package dp.creational.singleton;

import dp.utils.Utils;

public class HungrySingleton {

    private static HungrySingleton instance;
    private HungrySingleton() {}

    public static synchronized HungrySingleton getInstance() {
        if(instance == null) {
            Utils.sleep(10);
            instance = new HungrySingleton();
        }
        return instance;
    }
}
